Function: str2fieldname

CALL:

str = str2fieldname(str)

DESCRIPTION:

Convert string to fieldname that can be used in Matlab structure

INPUT:

str any
candidate fieldname

OUTPUT:

str any
Valid fieldname.
A.(str) = value will not give an error